home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / vol_100 / 187_01 / savedta.c < prev    next >
C/C++ Source or Header  |  1986-02-19  |  949b  |  27 lines

  1. /*@*****************************************************/
  2. /*@                                                    */
  3. /*@ savedta -  save the current DOS DTA for later.     */
  4. /*@                                                    */
  5. /*@   Usage:     savedta();                            */
  6. /*@                                                    */
  7. /*@       returns zero.                                */
  8. /*@                                                    */
  9. /*@       NOTE: restdta() restores it.                 */
  10. /*@                                                    */
  11. /*@*****************************************************/
  12.  
  13.  
  14. extern unsigned _rax, _rbx, _rcx, _rdx, _rsi, _rdi, _res, _rds;
  15. extern char _carryf, _zerof;
  16.  
  17. int dtads, dtadx;
  18.  
  19. savdta()
  20. {
  21.     _rax = 0x2f00;            /* get dta func */
  22.     _doint(0x21);            /* call DOS */
  23.     dtads = _res;            /* segment for dta */
  24.     dtadx = _rbx;            /* offset for dta */
  25.     return 0;
  26. }
  27.